<?xml version="1.0" encoding="utf-8" ?>
<Model xmlns="http://euss.evaluant.com/schemas/GenerationModel.xsd">

<Package name="MyNamespace">
	
<!-- Relations -->
	
	<Interface name="ICode">
		<Property name="Code" type="string" />
	</Interface>
	
	<Class name="Person" implement="ICode">
		<Property name="Birthday" type="DateTime?"/>
		<Property name="FirstName" type="string"/>
		<Property name="Age" type="int?"/>
    <Property name="Picture" type="System.Drawing.Image" />
	</Class>

  <Class name="Company" implement="ICode">
    <Property name="logo" type="string"/>
  </Class>

  <Relationship type="aggregation">
    <Parent name="Company" role="Companies" multiplicity="*"/>
    <Child name="Person" role="Employees" multiplicity="*"/>
  </Relationship>

  <!-- Héritage -->

  <Class name="SARL" inherit="Company"/>


  <!-- References cycliques -->

  <Relationship type="aggregation">
    <Parent name="Person" role="Colleagues" multiplicity="*"/>
    <Child name="Person" role="Friends" multiplicity="*"/>
  </Relationship>

  <Relationship type="aggregation">
    <Parent name="Person" role="Chief" multiplicity="1"/>
    <Child name="Person" role="Deputy" multiplicity="1"/>
  </Relationship>

  <!-- Cascading delete -->

  <Class name="Library">
    <Property name="name" type="string"/>
  </Class>

  <Class name="Shelf">
    <Property name="name" type="string"/>
  </Class>

  <Class name="Book">
    <Property name="name" type="string"/>
  </Class>

  <Relationship type="composition">
    <Parent name="Library" role="MyLibraries" multiplicity="1"/>
    <Child name="Book" role="MyBooks" multiplicity="*"/>
  </Relationship>

  <Relationship type="composition">
    <Parent name="Library" role="MyLibraries" multiplicity="1"/>
    <Child name="Shelf" role="Shelf" multiplicity="1"/>
  </Relationship>

  <Class name="BabyLibrary" inherit="Library"/>


  <!-- Enumeration -->

  <Enumeration name="Title">
    <Literal name="Miss"/>
    <Literal name="Madam"/>
    <Literal name="Sir"/>
  </Enumeration>

  <Relationship type="composition">
    <Parent name="Person" role="Person" multiplicity="1"/>
    <Child name="Title" role="Title" multiplicity="1"/>
  </Relationship>



  <Class name="Dog"/>

  <Relationship type="composition">
	<Parent name="Dog" role="ParentDog" multiplicity="1"/>
	<Child name="Dog" role="ChildDog" multiplicity="*"/>
</Relationship>

</Package>

</Model>
 
